package cn.ztr.ymcc.feign;

import cn.ztr.ymcc.feign.Impl.UserFeignImpl;
import cn.ztr.ymcc.result.JsonResult;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;

@FeignClient(value = "service-user",fallbackFactory = UserFeignImpl.class )
public interface UserFeign {
    /**
     * 根据手机号查找用户
     * @param phone
     * @return
     */
    @GetMapping("/user/findByPhone/{phone}")
    public JsonResult findByPhone(@PathVariable("phone")String phone);


}
